#ifndef CONSUMER_H
#define CONSUMER_H

class Server;
class OperationNode;

// Sends data from operationsRoot to consume it by server.
class Consumer {
	public:
		// Takes ownership of operationsRoot.
		// Doesn't take ownership of server.
		Consumer(OperationNode* operationsRoot, Server* server);
		~Consumer();

		void consume();

	private:
		Consumer(const Consumer&);

		OperationNode* _operationsRoot;
		Server* _server;
};

#endif
